<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改设备状态列表')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-state-edit" th:object="${deviceState}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label">设备编号：</label>
                <div class="col-sm-8">
                    <input name="deviceNo" th:field="*{deviceNo}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">机型：</label>
                <div class="col-sm-8">
                    <input name="deviceModel" th:field="*{deviceModel}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">焊机状态：</label>
                <div class="col-sm-8">
                    <input name="deviceState" th:field="*{deviceState}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">锁定禁用：</label>
                <div class="col-sm-8">
                    <input name="lockState" th:field="*{lockState}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">预置电流(A)：</label>
                <div class="col-sm-8">
                    <input name="presetCurrent" th:field="*{presetCurrent}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">预置电压(V)：</label>
                <div class="col-sm-8">
                    <input name="presetVoltage" th:field="*{presetVoltage}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">焊接电流(A)：</label>
                <div class="col-sm-8">
                    <input name="weldingCurrent" th:field="*{weldingCurrent}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">焊接电压(V)：</label>
                <div class="col-sm-8">
                    <input name="weldingVoltage" th:field="*{weldingVoltage}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">报警代码：</label>
                <div class="col-sm-8">
                    <input name="alarmCode" th:field="*{alarmCode}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">操作人员：</label>
                <div class="col-sm-8">
                    <input name="operators" th:field="*{operators}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">焊缝编号：</label>
                <div class="col-sm-8">
                    <input name="weldNo" th:field="*{weldNo}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">材质：</label>
                <div class="col-sm-8">
                    <input name="material" th:field="*{material}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">丝径：</label>
                <div class="col-sm-8">
                    <input name="diameter" th:field="*{diameter}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">气体：</label>
                <div class="col-sm-8">
                    <input name="gas" th:field="*{gas}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">是否启用：</label>
                <div class="col-sm-8">
                    <input name="isValid" th:field="*{isValid}" class="form-control" type="text">
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "device/state";
        $("#form-state-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-state-edit').serialize());
            }
        }
    </script>
</body>
</html>